package com.breaktian.demoapp.ui.fragment;

import android.os.Bundle;
import android.support.v4.app.Fragment;

import com.breaktian.demoapp.provider.BaseProvider;

/**
 * Created by tiankeke on 2017/6/7.
 */

public abstract class BaseFragment<P extends BaseProvider> extends Fragment {

    protected P mProvider;

    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        this.mProvider = getProvider();
    }

    //设置数据提供者
    protected abstract P getProvider();
}
